home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part2 / 10378 < prev    next >
Encoding:
Text File  |  1996-08-05  |  583 b   |  24 lines

  1. Path: csulb.edu!davidcho
  2. From: davidcho@csulb.edu (David Cho)
  3. Newsgroups: comp.lang.c
  4. Subject: Urgent:  pow() in TurboC
  5. Date: 17 Mar 1996 11:27:01 GMT
  6. Organization: Cal State Long Beach
  7. Message-ID: <4igsu5$q1t@hatathli.csulb.edu>
  8. NNTP-Posting-Host: heart.engr.csulb.edu
  9. X-Newsreader: TIN [version 1.2 PL2]
  10.  
  11. void main() {
  12.  
  13. long int k;
  14.  
  15.   k = pow(2,23);
  16.  
  17. }
  18.  
  19. When I try this, k gets 0.0.  Then I try smaller numbers like (2,3) and I 
  20. still get 0.0.  So I change the parameters to (2.0, 3.0) and I get 
  21. 255.00.  What is going on here?
  22.  
  23. Is there a bug in the compiler?  Please e-mail me.
  24.